package com.cykj.controller;


import com.cykj.dto.ResponseDTO;
import com.cykj.service.IOrderService;
import org.springframework.beans.factory.annotation.Autowired;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/order")
public class OrderController {

    @Autowired
    private IOrderService orderService;

    @RequestMapping("/buy")
    public ResponseDTO buy(Integer userId, Integer goodId, Integer count) {
        return orderService.buy(userId,goodId, count);
    }

}
